<!DOCTYPE html>
<!--[if lt IE 7]>      <html class='no-js lt-ie9 lt-ie8 lt-ie7'> <![endif]-->
<!--[if IE 7]>         <html class='no-js lt-ie9 lt-ie8'> <![endif]-->
<!--[if IE 8]>         <html class='no-js lt-ie9'> <![endif]-->
<!--[if gt IE 8]><!--> <html class='no-js'> <!--<![endif]-->
<head>
  <meta charset='utf-8'>
  <meta http-equiv='X-UA-Compatible' content='IE=edge'>
  <title>Global Forest Watch</title>

  <link href='http://fonts.googleapis.com/css?family=Fira+Sans:400,500,300' rel='stylesheet' type='text/css'>


  <meta name='description' content='Global Forest Watch (GFW) is a partnership that provides the most current, reliable, and actionable information about what is happening in forests worldwide.'>
  <meta name="keywords" content="<%= @keywords %>">
  <meta name='viewport' content='width=device-width, initial-scale=1'>
  <meta name='robots' content='noindex'>
  <meta name="google-site-verification" content="xx82D6cZ40Hvf-TT9jkhfsVi11yIeShPcK0zcc7m7ak" />
  <%= favicon_link_tag 'favicon.ico' %>

  <%= controller_stylesheet_link_tag %>
  <%= yield :css %>
  <style>
    body {
      border: 0;
      overflow: hidden;
    }

    .footer {
      margin: 0;
      padding: 20px;
      background: #FFF;
      color: #999;
      border-top: 1px solid #CCC;
      z-index: 100;
      position: relative;
      z-index: 300;
    }
    .footer a{
      margin: 0 auto;
      display: block;
      max-width: 300px;
    }
    .show_graph_source {
      font-size: 10px;
      position: absolute;
      bottom: 100%;
      left: 0;
      padding: 4px;
      color: #FFF;
    }

    .left { float: left; }
    .right { float: right; }
  </style>

  <%= javascript_include_tag 'modernizr-2.6.2.min' %>
  <%= csrf_meta_tags %>
  <script>
    if (! !!window.gfw) {
      var gfw = window.gfw = {
        config: {
          GFW_API_HOST: "<%= ENV['GFW_API_HOST'] %>",
          GFW_MOBILE: 1000
        },
        cacheVersion: "<%= ENV['CACHE_VERSION'] %>",
        layer_spec: "<%= ENV['LAYER_SPEC'] %>"
      };
    }
  </script>
</head>
<body class='<%= "#{controller_name} #{action_name}" %>'>
  <%= yield :title %>

  <%= yield %>

  <footer class="footer">
    <div class="show_graph_source">Source: Hansen/UMD/Google/USGS/NASA</div>
  <% if @country %>
    <a class="btn green uppercase full-width" href="http://globalforestwatch.org/country/<%= @country['iso']%>" target="_blank">View on GFW</a>
  <% else %>
    <a class="btn green uppercase full-width" href="http://globalforestwatch.org/countries/overview%>" target="_blank">View on GFW</a>
  <% end %>
  </footer>
  <div class="backdrop"></div>
  <%= render 'shared/js_templates' %>

  <script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?libraries=drawing,geometry&sensor=false"></script>
  <script src="http://libs.cartocdn.com/cartodb.js/v3/cartodb.js"></script>
  <%= requirejs_include_tag "countries" %>
  <%= render 'shared/js_footer' %>
</body>
</html>
